﻿<UserControl x:Class="SellAvi.Views.ControlCaptcha"
      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
      mc:Ignorable="d"
	>
    <UserControl.CommandBindings>
        <CommandBinding Command="ApplicationCommands.Close"
                        Executed="CloseCommandHandler"/>
    </UserControl.CommandBindings>

    <Grid Margin="20">
        <Grid.Resources>
            <Style TargetType="{x:Type TextBox}">
                <Setter Property="Margin" Value="0,2,0,2" />
            </Style>
        </Grid.Resources>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto" />
            <RowDefinition Height="24" />

        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>
        <Image Grid.Row="0" Grid.Column="0" Height="30" Width="90" Source="{Binding CaptchaImagePath}" Stretch="UniformToFill"></Image>
        <DockPanel Grid.Row="1" Grid.Column="0">
            <Button DockPanel.Dock="Right"
                    IsDefault="True"
                    Command="ApplicationCommands.Close">
                <Image Source="/SellAvi;component/Resources/forward.png" Width="14"></Image>
            </Button>
            <!--<Button DockPanel.Dock="Right" Command="{Binding ConfirmProductCommand}">
                <Image Source="/SellAvi;component/Resources/loop.png" Width="14"></Image>
            </Button>-->
            <TextBox HorizontalAlignment="Stretch" Text="{Binding ResolvedCaptchaText}"></TextBox>
        </DockPanel>
    </Grid>
</UserControl>
